package com.pearl.jacksoncore.demo.databind.anno;

import com.fasterxml.jackson.annotation.*;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;

/**
 * @author TD
 * @version 1.0
 * @date 2024/3/26
 */

@JsonIncludeProperties({"id","name"})
public class LoginUser {

    @JsonSerialize
    private Long id;

    private String name;

    //@JsonView({UserInfoView.SensitiveView.class,UserInfoView.VerySensitiveView.class})
    private String idCard;

    //@JsonView({UserInfoView.SensitiveView.class,UserInfoView.VerySensitiveView.class})
    private String phone;

    //@JsonView(UserInfoView.VerySensitiveView.class)
    private String pwd;

    public String getPwd() {
        return pwd;
    }

    public void setPwd(String pwd) {
        this.pwd = pwd;
    }

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getIdCard() {
        return idCard;
    }

    public void setIdCard(String idCard) {
        this.idCard = idCard;
    }

    public String getPhone() {
        return phone;
    }

    public void setPhone(String phone) {
        this.phone = phone;
    }

    @Override
    public String toString() {
        return "LoginUser{" +
                "id=" + id +
                ", name='" + name + '\'' +
                ", idCard='" + idCard + '\'' +
                ", phone='" + phone + '\'' +
                ", pwd='" + pwd + '\'' +
                '}';
    }
}
